package nccloud.web.arap.mullevelpay.mullevelpayvo.action;

import java.util.Map;

import nc.itf.arap.mullevelpay.mullevelpayvo.IMulLevelPayVOService;
import nccloud.framework.service.ServiceLocator;
import nccloud.framework.web.container.IRequest;
import nccloud.web.codeplatform.framework.action.base.BaseAction;
import nccloud.web.codeplatform.framework.action.base.RequestDTO;
import nccloud.web.codeplatform.framework.action.base.RequstParamWapper;
import nccloud.web.codeplatform.framework.action.base.VOTransform;

public class LinkPzAction extends BaseAction {

	@Override
	public Object doAction(IRequest arg0, RequstParamWapper paramWapper) throws Throwable {
		RequestDTO param = VOTransform.toVO(paramWapper.requestString,RequestDTO.class);
		Map<String,String> tsMap = param.getTsMap();
		IMulLevelPayVOService service = ServiceLocator.find(IMulLevelPayVOService.class);
		String[] pks = new String[tsMap.size()];
		int i = 0;
		for(String pk:tsMap.keySet()) {
			pks[i] = pk;
			i++;
		}
		String result = service.linkPz(pks);
		return result;
	}

}
